import java.util.Scanner;

public class Throw_ {
    public static void main(String[] args) {
        test();
    }

    public static void test(){
        System.out.println("请输入1-10");
        Scanner scanner = new Scanner(System.in);
        int input = scanner.nextInt();
        if(!(input >= 1 && input <= 10)){
            throw new DataBoundException("输入不在指定范围内");
        }
    }
}

class DataBoundException extends RuntimeException{
    private String message;
    public DataBoundException(String message) {
        super(message);
        this.message = message;
    }
    public void Tell(){
        System.out.println("你小子输入有误！" + message);
    }
}